package com.zenith.yasoo.setup;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import com.sun.istack.internal.NotNull;


@Entity
@Table(name="contact_mech_purpose_type")
public class ContactMechPurposeType {
	private static final long serialVersionUID = 1L;
	
	private String contactMechPurposeTypeCode;
	private String contactMechPurposeTypeName;
	private ContactMechType contactMechType;
	
	/*------------------------------
	 * getters and annotations
	 --------------------------------*/
	@Id @Column(length=20)
	public String getContactMechPurposeTypeCode() {return contactMechPurposeTypeCode;}
	@Column(length=50) @NotNull
	public String getContactMechPurposeTypeName() {return contactMechPurposeTypeName;}
	@ManyToOne() @JoinColumn(name="contactMechTypeCode")
	public ContactMechType getContactMechType() {return contactMechType;}
	
	
	public void setContactMechType(ContactMechType contactMechType) {
		this.contactMechType = contactMechType;
	}
	public void setContactMechPurposeTypeCode(String contactMechPurposeTypeCode) {
		this.contactMechPurposeTypeCode = contactMechPurposeTypeCode;
	}
	public void setContactMechPurposeTypeName(String contactMechPurposeTypeName) {
		this.contactMechPurposeTypeName = contactMechPurposeTypeName;
	}	
}
